Txt2Site Website Builder
Quickstart


Quickstart

Creating a website with Txt2Site is easy. You can build a simple website in a one minute. Here is a guide to make a quickstart with HTML as markup language.

1. Setup

2. Generate default application environment

Open a terminal window with a working directory where you want to put your application.
Execute the next commands:

  $ txt2site  -n  my_demo
  $ txt2site  -g  my_demo/my_demo.conf 

This first command creates a file structure for the application in the working directory. The root directory of the application is my_demo.
The second command generates a website with a default layout. You can view the website by opening with your browser the index.html file in the directory my_demo/site/target. The website has one page.

3. Write content

The file default in the directory my_demo/content is a content file. This file is the source of the content of the website page. Adjust some text after the header HELLO WORLD and save it. Verify the changes you have made by executing:

  $ txt2site  -g  my_demo/my_demo.conf 

4. Create pages

Verify that new pages are added to the website. Look at the navigation menu on top of the page.

5. Create subdirectories

Verify that a new page Other Animals is added to the website. Hover over Other Animals in the menu to see the new pages Dog and Cat.

6. Sorting menu items

Rename content files and content directories by putting a prefix of the format 999_ before the name.
For example: rename Cow, Monkey and Chicken to 001_Cow, 002_Monkey and 003_Chicken.
After generating the site look how the sort order of items in the navigation menu are changed according to these prefixes. Note that prefixes are not visible in the menu items.
Do not put a prefix before the content file default; the name default is fixed.

7. Customize site layout

Txt2Site adds layout and navigation elements to each page. To change the site look and feel, play with the following files:

For example:
The configuration file my_demo.conf has stylesheet variables which defines the colors of the website. Change one of these variables and see the result after generating a new site. Remember that colors can be referenced by name: red, blue, green, yellow, orange, etc.





^ View Contentfile
© 2013 Arthur Kalverboer Powered by Txt2Site Last changed: 2013-12-21 09:44